<?php $tpl->addCSS('css/review.css'); ?>

<?php if (!@$price) { ?>
<h2><?php echo $heading_title; ?></h2>
<?php } else { ?>
<h2>
  <div class="left"><?php echo $heading_title; ?></div>
  <div class="right"><?php echo @$price; ?></div>
</h2>
<?php } ?>
<div class="results"> 
  <div class="left"><?php echo $text_results; ?></div>
  <div class="right pagination">
  <span id="entry_page"><?php echo $entry_page; ?></span>
  <?php foreach ($pages as $p) { ?>
  <a href="<?php echo $p['href']; ?>"<?php if ($p['value'] == $page) { ?> id="current"<?php } ?>><?php echo $p['value']; ?></a>
  <?php } ?>
  </div>
</div>
<div id="review">
  <?php if (@$reviews) { ?>
  <?php foreach ($reviews as $review) { ?>
  <div class="a">
    <div class="b"><a href="<?php echo $review['href']; ?>" ><?php echo $review['name']; ?></a> <?php echo $text_review_by; ?> <?php echo $review['author']; ?></div>
    <div class="c"><b><?php echo $text_date_added; ?></b> <?php echo $review['date_added']; ?></div>
    <table>
      <tr>
        <td rowspan="2"><a href="<?php echo $review['href']; ?>"><img src="<?php echo $review['thumb']; ?>" alt="<?php echo $review['name']; ?>" class="d" /></a></td>
        <td><?php echo $review['text']; ?></td>
      </tr>
      <tr>
        <td><b><?php echo $text_rating; ?></b> <img src="<?php echo $tpl->getImage('image/stars_' . $review['rating'] . '.png'); ?>" alt="<?php echo $review['out_of']; ?>" class="png" /><br />
          (<?php echo $review['out_of']; ?>)</td>
      </tr>
    </table>
  </div>
  <?php } ?>
  <?php } ?>
</div>
<div class="buttons">
  <table>
    <tr>
      <td align="right"><input class="button_write" type="button" value="<?php echo $button_write; ?>" onclick="location='<?php echo $write; ?>'" /></td>
    </tr>
  </table>
</div>